<template>
	<view>
		detail02
		uni-app 常用的页面生命周期函数：
		<!-- 左边是选项式api  右边式组合式api -->
		 onLoad(options) -> onload
		 onShow -> onShow
		 onReady -> onReady
		 onHide -> onHide
		 onUnload -> onUnload
		 onPullDownRefresh -> onPullDownRefresh
		 onReachBottom -> onReachBottom
		<view class="item">
			item
		</view><view class="item">
			item
		</view><view class="item">
			item
		</view><view class="item">
			item
		</view><view class="item">
			item
		</view><view class="item">
			item
		</view><view class="item">
			item
		</view><view class="item">
			item
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			};
		},
		// 1,页面的生命周期
		onLoad() {
			console.log('02 onLoad');
		},
		onShow() {
			console.log("02 onshow");
		},
		onReady() {
			console.log("02 onready");
		},
		onHide() {
			console.log("02 onhide");
		},
		onUnload() {
			console.log("02 unload");
		},
		onPullDownRefresh() {
			console.log("02 下拉刷新");
			setTimeout(()=>{
				uni.stopPullDownRefresh()
			},1000)
		},
		onReachBottom() {
			console.log("02 触底");
		},
		// 2,组件生命周期
		beforeCreate() {
			console.log("02 beforeCreate");
		},
		created() {
			console.log("02 created");
		},
		beforeMount() {
			console.log("02 beforeMount");
		},
		mounted() {
			console.log("02 mounted");
		},
		beforeDestroy() {
			console.log("02 beforeDestroy");
		},
		deactivated() {
			console.log("02 deactivated");
		}
	}
</script>

<style lang="scss">
.item{
	height: 400rpx;
	border: 1px solid #000;
}
</style>
